import Vue from 'vue'
import App from './App'

import store from './store'
import '../js_sdk/ican-H5Api/ican-H5Api'
import global_ from './Base.vue'
import './static/icon/iconfont';
import './static/icon/iconfont2.css';
Vue.config.productionTip = false

Vue.prototype.GLOBAL = global_
App.mpType = 'app'
Vue.prototype.$store = store
Vue.prototype.$eventHub = new Vue(); //子页面向父页面传值
const showToast = (title, duration=1500, mask=false, icon='none')=>{
	//统一提示方便全局修改
	if(Boolean(title) === false){
		return;
	}
	uni.showToast({
		title,
		duration,
		mask,
		icon
	});
}
const showLoading = (title, mask=true)=>{
	//统一提示方便全局修改
	if(Boolean(title) === false){
		return;
	}
	uni.showLoading({
		title,
		mask
	});
}
Vue.prototype.$msg = {showToast, showLoading}
const app = new Vue({
  store,
  ...App
})
app.$mount()
